CXXFLAGS =	-O2 -g -Wall -fmessage-length=0 $(INCLUDES)

COMN_DIR=../comn
THIRD_PARTY = ../third_party
RTSPCASTER_DIR =../RtspCaster
RTPCASTER_DIR  =../RtpCaster
RTSPRELAY_DIR  =../RtspRelay
GLOOX_DIR=../third_party/gloox-1.0.14

SOURCE = $(wildcard *.cpp )
OBJS =	$(SOURCE:.cpp=.o)


INCLUDES = -I. \
	-I./include -I./src -I./rtp \
	-I$(COMN_DIR)/include \
	-I$(RTSPCASTER_DIR) \
	-I$(RTPCASTER_DIR) \
	-I$(RTSPRELAY_DIR) \
	-I$(GLOOX_DIR)/src \
	
LIBS = -lpthread \
	-L$(COMN_DIR)/lib -lcomn \
	-L../lib \
	-lRtspCaster -lRtpCaster \


TARGET = LiveRelayServer


$(TARGET):	$(OBJS)
	$(CXX) -o $(TARGET) $(OBJS) $(LIBS)

all:	$(TARGET)

clean:
	rm -f $(OBJS) $(TARGET)
